﻿Module module2
    Function tinhtong(ByVal n As Integer)
        Dim S As Single = 0
        For i As Integer = 0 To n
            S += (i + 1) / (i + 2)
        Next
        Return S
    End Function

    Function luythua(ByVal x As Single, ByVal n As Integer)
        Dim lt As Integer = 1
        For i As Integer = 1 To n
            lt *= x
        Next
        Return lt
    End Function

    Function Tong(ByVal x As Single, ByVal n As Integer)
        Dim S As Single = 0
        For i As Integer = 1 To n
            S += luythua(x, n)
        Next
        Return S
    End Function
End Module
